.PHONY:	clean fclean re
DIR=		.
OUT=		liblist.a
CFILES=	list_add.c\
				list_append.c\
				list_apply.c\
				list_apply_r.c\
				list_get.c\
				list_remove.c\
				list_reverse.c\
				list_size.c\
				list_sort.c\
				list_sorted_merge.c\
				list_split.c
OBJ=		$(CFILES:.c=.o)
CFLAGS=	-W -Wall -pedantic -ansi -O2

all:	$(OBJ)
	@ar -r $(DIR)/$(OUT) $(OBJ)

%.o: %.c
	gcc -o $@ -c $< $(CFLAGS)

clean:
	rm -f $(OBJ)

fclean: clean
	rm -f $(DIR)/$(OUT)

re: fclean all
	
